<?php

$ARTICLES = new articles();


# RESTORE ARTICLES FROM TRASHCAN
if (isset($_POST['recover']))
{
   $ARTICLES->recovery($_POST['recover']);
}

# DELETE ARTICLES FROM TRASHCAN
if(!empty($_POST['delete']))
{
   $ARTICLES->delete($_POST['delete']);
}


# LOAD ARTICLES FROM TRASHCAN
paginator::setItemsOnPage($categories[12]->i_onpage);
$ARTICLES->setOrder('`deleted` DESC');
$data = $ARTICLES->getArticles(array('deleted'=>TRUE));
$SMARTY->assign('data', $data);

$layout = 'trashcan.html';